﻿using System.Web;

namespace Noria.Web.Utility
{
    internal static class ClientHelper
    {
        public static string GetIPAddress(HttpRequest request)
        {
            string szRemoteAddr = request.UserHostAddress;
            string szXForwardedFor = request.ServerVariables["X_FORWARDED_FOR"];
            return szXForwardedFor ?? szRemoteAddr;
        }
    }
}